package com.sudo.boot.service.sys.converter;

import com.sudo.boot.common.constant.ConstantSys;
import com.sudo.boot.mapper.sys.entity.SysMenu;
import com.sudo.boot.mapper.sys.model.bo.SysMenuBoAdd;
import com.sudo.boot.mapper.sys.model.bo.SysMenuBoAddSub;
import com.sudo.boot.mapper.sys.model.bo.SysMenuBoEdit;
import com.sudo.boot.mapper.sys.model.vo.SysMenuDetailVo;
import com.sudo.boot.mapper.sys.model.vo.SysMenuVo;
import org.mapstruct.Builder;
import org.mapstruct.Mapper;
import org.mapstruct.ReportingPolicy;

import java.util.List;

@Mapper(builder = @Builder(disableBuilder = true), componentModel = ConstantSys.SPRING,unmappedTargetPolicy = ReportingPolicy.IGNORE)
public interface SysMenuConverter {

    List<SysMenuVo> toSysMenuVoList(List<SysMenu> sysMenuList);

    SysMenu toSysmenu(SysMenuBoAddSub bo);

    SysMenu toSysmenu(SysMenuBoAdd bo);

    SysMenu toSysMenu(SysMenuBoEdit bo);

    SysMenuDetailVo toSysMenuDetailVo(SysMenu sysMenu);
}